package mypackage.servicce.Impl;

import mypackage.bean.Clients;
import mypackage.dao.ClientsDao;
import mypackage.dao.impl.ClientsImpl;
import mypackage.servicce.ClientsService;

import java.util.List;

/**
 * @author YH925
 * @create 2021/12/7 20:45
 */
public class ClientsServiceImpl implements ClientsService {

    private final ClientsDao dao = new ClientsImpl();

    @Override
    public Clients clientsLogin(Clients clients) {
        return dao.clientsLogin(clients);
    }

    @Override
    public void clientRegister(String username, String password) {
        dao.clientRegister(username, password);
    }

    //根据用户名查找用户名
    @Override
    public Clients selectClientByName(String username) {
        return dao.selectClientByName(username);
    }

    @Override
    public Clients findClientById(int id) {
        return dao.findClientById(id);
    }

    @Override
    public List<Clients> findAllClients() {
        return dao.findAllClients();
    }
}
